package cn.com.api.service;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Service;

import cn.com.api.entity.ApiT_products;
import cn.com.api.service.base.T_memberServiceBase;
import cn.com.api.service.base.T_productsServiceBase;
import cn.com.util.*;

/**
 * 
 */
@Service
public interface ApiT_productsService extends T_productsServiceBase {

	//
	public List<Map<String, Object>> findProductsByGoodsId(Long goods_id);

	// 反馈新增product_id
	public int insertT_productsReturnId(ApiT_products t_products);
	
	public List<Map<String,Object>> searGoodIdAndCityId(String goods_id,String cityid);

	/**
	 * 得到没有被删除的Products
	 * @param goods_id
	 * @return
	 */
	public List<ApiT_products> getUndeletedProductsByGoodsId(Long goods_id);

	// 根据erp货品编码查询 所有仓库的货品  
	public List<ApiT_products> findProductsByErpProductId(String erp_product_id);
	
	
	public boolean updateTopOrDel(String del,String status,String id);
	
	//根据商品名称搜索商品
	public void searchProductsByGoodName(Map<String, String> params,Map<String, Object> map);
	
	//购物车生成订单时，商品库存数量减少，已售数量增加
	public void modifyProductCountByCarId(Integer car_id);
	
	//取消的订单---根据订单号、查询购物车记录，恢复库存，已售数量
	public void modifyProductCountByOrderId(String orderId);
	
	//将订单抛给erp成功后，本地erp库存先减少
	
	public boolean updatePriceByPro(String price,String proid,String store);
	
	public String searStoreByProId(String proid);
	
	public List<ApiT_products> findZiYingproductss();
	
	public List<ApiT_products> searchProducts(Map<String,Object> conditions,PageInfo pageInfo);
	
	public Map<String,Object> getGoodsInfoByProductId(String productId);

	public String getProductNameProductId(String productId);
}
